@import 'theme';
@import 'functions';
@import 'mixins';

$cx-search-container-trbl-margin: 40px 0 !default;

$cx-search-sorting-border-color: 'light' !default;
$cx-search-sorting-border: 1px solid !default;

$cx-search-sorting-top-trbl-padding: 0 0 8px 0 !default;

$cx-search-sorting-bottom-trbl-padding: 25px 0 0px 0 !default;

$cx-product-search-dropdown-trbl-padding: 0 35px 0 0 !default;
$cx-product-search-dropdown-height: 48px !default;

$cx-search-list-border: 1px solid;
$cx-search-list-border-color: 'light' !default;
$cx-search-list-trbl-margin: 0 0 25px 0;

.cx-product-search {
  &-list {
    display: block;
    border-bottom: $cx-search-list-border;
    @include var-color('border-color', $cx-search-list-border-color);
    margin: $cx-search-list-trbl-margin;

    &:last-of-type {
      border-bottom: none;
    }
  }

  &__item--container {
    margin: $cx-search-container-trbl-margin;
  }

  &__sorting {
    &--top {
      border-bottom: $cx-search-sorting-border;
      @include var-color('border-color', $cx-search-sorting-border-color);
      padding: $cx-search-sorting-top-trbl-padding;

      @include media-breakpoint-down(md) {
        border-bottom: none;
      }
    }

    &--bottom {
      border-top: $cx-search-sorting-border;
      @include var-color('border-color', $cx-search-sorting-border-color);
      padding: $cx-search-sorting-bottom-trbl-padding;

      @include media-breakpoint-down(md) {
        border-top: none;
      }
    }
  }
}

.cx-product-search__pagination {
  display: inline-block;
  vertical-align: top;
}

.cx-product-search__dropdown {
  height: $cx-product-search-dropdown-height;

  .ng-arrow-wrapper {
    padding: $cx-product-search-dropdown-trbl-padding;
  }
}
